<template>
  <el-input v-model="input" class="w-50 m-2 search-input" placeholder="搜索" :suffix-icon="Search" @keyup.enter="handleEnter" />
</template>

<script lang="ts" setup>
import { ref } from 'vue'
import { Search } from '@element-plus/icons-vue'

const input = ref('')
function handleEnter () {
  console.log(input.value)
}
</script>
<style scoped>
.search-input {
  margin-top: 10px;
}
</style>
